package com.htj.erp.model.jpa;
import java.util.List;
import com.htj.erp.model.BaseEntity;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.OneToMany;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.CascadeType;

import java.util.Date;
/**
 * 
 *
 * 
 * Orderh
 * orderh
 *
 * chenghongtao
 * 2016-11-07 15:30:50
 * HTJ
 * @version 1.0.0
 *
 */
@Entity
@Table(name = "orderh")
public class Orderh extends BaseEntity {
	
	public static final Integer STATUS_INIT = 0;
	public static final Integer STATUS_SUBMIT = 1;
	public static final Integer STATUS_SENDING = 5;
	public static final Integer STATUS_CLOSED = 10;
	
	private static final long serialVersionUID = 1L;
	
	/**
	*客户ID
	*/
	@Column(name = "cus_id")
	private Long cusId;
	/**
	*客户姓名
	*/
	@Column(name = "cus_name")
	private String cusName;
	/**
	*订单日期
	*/
	@Column(name = "order_date")
	private Date orderDate;
	/**
	*订单类型
	*/
	@Column(name = "order_type")
	private String orderType;
	/**
	*总额
	*/
	@Column(name = "total_amount")
	private Float totalAmount;
	/**
	*备注
	*/
	@Column(name = "remark")
	private String remark;
	/**
	*状态
	*/
	@Column(name = "status")
	private Integer status;

	/**
	*orderb
	*订单明细
	*/
	@OneToMany(mappedBy = "orderh")  
	private List<Orderb>  orderbs;


	/**
	*获取 客户ID
	*/
	public Long getCusId(){
		return cusId;
	}
	
	/**
	*设置 客户ID
	*/
	public void setCusId(Long cusId){
		this.cusId = cusId;
	}
	/**
	*获取 客户姓名
	*/
	public String getCusName(){
		return cusName;
	}
	
	/**
	*设置 客户姓名
	*/
	public void setCusName(String cusName){
		this.cusName = cusName;
	}
	/**
	*获取 订单日期
	*/
	public Date getOrderDate(){
		return orderDate;
	}
	
	/**
	*设置 订单日期
	*/
	public void setOrderDate(Date orderDate){
		this.orderDate = orderDate;
	}
	/**
	*获取 订单类型
	*/
	public String getOrderType(){
		return orderType;
	}
	
	/**
	*设置 订单类型
	*/
	public void setOrderType(String orderType){
		this.orderType = orderType;
	}
	/**
	*获取 总额
	*/
	public Float getTotalAmount(){
		return totalAmount;
	}
	
	/**
	*设置 总额
	*/
	public void setTotalAmount(Float totalAmount){
		this.totalAmount = totalAmount;
	}
	/**
	*获取 备注
	*/
	public String getRemark(){
		return remark;
	}
	
	/**
	*设置 备注
	*/
	public void setRemark(String remark){
		this.remark = remark;
	}
	/**
	*获取 状态
	*0: 草稿
	*1：已确认
	*
	*5：送货中
	*
	*10：已完成
	*
	*
	*/
	public Integer getStatus(){
		return status;
	}
	
	/**
	*设置 状态
	*/
	public void setStatus(Integer status){
		this.status = status;
	}

	/**
	*获取 orderb 
	*订单明细
	*/
	public List<Orderb> getOrderbs(){
		return orderbs;
	}

	/**
	*设置 orderb 
	*订单明细
	*/
	public void setOrderbs(List<Orderb> orderbs){
		this.orderbs = orderbs;
	}



}